<?php
/**
 * @table(FooBar) 
 */
class User extends slObject {
	
	/** 
	 * @id
	 * @unsigned
	 */
	public $userId;
	
	/**
	 * @maxLength(256)
	 * @notNull 
	 */
	public $username;
	
	/** @transient */
	public $password;
	
	/** 
     * @exactly(32)
 	 */
	public $passwordHash;
	
	/** 
	 * @date 
	 */
	public $created;
	
	/** @boolean */
	public $enabled;
	
	/** 
	 * @blob 
	 * @comment(This is my rifle, this is my gun.  This is for fighting, this is for fun.) 
	 */
	public $blob;
	
	/**
	 * @integer
	 * @zerofill
	 */
	public $integer;
	
	/**
	 * @oneToMany(Password)
	 * @owner
	 */
	function getPasswordHistory(){}
	
	/**
	 * @manyToOne(JobType)
	 * @owner
	 */
	function getJobType(){}
	
	/**
	 * @oneToOne(Employee)
	 */
	function getEmployee(){}
	
	/**
	 * @manyToMany(Action)
	 */
	function getActions(){}
	
}

/** @table(PasswordHistory) */
class Password extends slObject {

	/** @id */
	public $passwordId;
	
	/** 
	 * @exactly(32)
	 * @notNull
	 */
	public $passwordHash;
	
	/**
	 * @date
	 * @notNull
	 */
	public $created;
	
	/**
	 * @manyToOne(User)
	 */
	function getUser(){}
	
}

class Employee extends slObject {
	
	/** @id */
	public $employeeId;

	public $firstName;
	
	public $lastName;
	
	/** @date */
	public $hired;
	
	/**
	 * @oneToOne(User)
	 */
	function getUser(){}
	
}

class JobType extends slObject {

	public $name;
	
	/**
	 * @oneToMany(User)
	 */
	function getUsers(){}
	
}

class Action extends slObject {

	/** @id */
	public $actionId;
	
}